<template>
	<view>
		<view class="person-active-left">
			<view class="person-fans">
				<p>{{interest}}</p>
				<h4>关注</h4>
			</view>
			<view class="person-fans">
				<p>{{fans}}</p>
				<h4>粉丝</h4>
			</view>
			<view class="person-fans">
				<p>{{collect}}</p>
				<h4>获赞与收藏</h4>
			</view>
		</view>
		<view class="person-active-right">
			<button type="normal" size="mini" class="person-button">编辑</button>
			<icon type="text" size='26' class="iconfont icon-Setting icon-config"></icon>
		</view>
	</view>
</template>

<script>
	import {
		getUserInfo,
		getLikeAndCollect
	} from '@/api/personal.js'
	
	export default {
		data() {
			return {
				// 粉丝
				fans: 2,
				// 获赞
				collect: 3,
				// 关注
				interest: 2
			}
		},
		onLoad() {

		},
		methods: {
			/**
			 * 获取用户点赞和收藏
			 */
			async functionGetUserLikeAndCollect() {
				let response = await getLikeAndCollect()
				this.collect = response.data
			},
		}
	}
</script>

<style lang="scss" scoped>
	@import url('/static/asset/icons/sex_icon.scss');
	@import url('/static/asset/settings/settings.scss');

	.person-active {
		display: flex;
		justify-content: space-around;
		width: 100%;
		padding: 45rpx 0rpx;

		.person-active-left {
			display: flex;
			justify-content: space-around;
			width: 50%;

			.person-fans {
				display: flex;
				flex-direction: column;
				justify-content: center;
				align-items: center;

				p {
					font-size: 13px;
				}

				h4 {
					padding-top: 15rpx;
					font-size: 12px;
					font-weight: 500;
				}
			}
		}

		.person-active-right {
			display: flex;
			width: 50%;
			justify-content: space-around;
			align-items: center;

			.person-button {
				background-color: rgba(85, 90, 80, .7);
				height: 60rpx;
				line-height: 60rpx;
				color: white;
				margin-right: 30rpx;
				border: 1px solid white;
				border-radius: 30rpx;
			}

			.icon-config {
				background-color: rgba(85, 90, 80, .7);
				font-size: 22px;
				height: 60rpx;
				line-height: 60rpx;
				padding: 0rpx 20rpx;
				border: 1px solid white;
				margin-right: 30rpx;
				border-radius: 30rpx;
			}
		}
	}
</style>